﻿@model kxcxw.Data.Entities.SysUserInfo
@{
    ViewBag.Title = "添加新用户";
    Layout = "~/Areas/Admin/Views/Shared/_UserInfoLayout.cshtml";
}
<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>
<h2>
    @Html.ActionLink("用户管理", "Index") &raquo; @Html.ActionLink("添加用户", "Create", null, new { @class = "active" })</h2>
<div id="main">
    @using (Html.BeginForm("Create", "UserInfo", FormMethod.Post, new { name = "jNice", @class = "jNice" }))
    {
        @Html.ValidationSummary(true)
        <fieldset>
            <div class="field">
                <div class="editor-label">
                    @Html.LabelFor(model => model.UserName)
                </div>
                <div class="editor-field">
                    @Html.EditorFor(model => model.UserName)
                    @Html.ValidationMessageFor(model => model.UserName)
                </div>
                <div class="editor-label">
                    @Html.LabelFor(model => model.NickName)
                </div>
                <div class="editor-field">
                    @Html.EditorFor(model => model.NickName)
                    @Html.ValidationMessageFor(model => model.NickName)
                </div>
            </div>
            <div class="field">
                <div class="editor-label">
                    @Html.LabelFor(model => model.UserPwd)
                </div>
                <div class="editor-field">
                    @Html.EditorFor(model => model.UserPwd)
                    @Html.ValidationMessageFor(model => model.UserPwd)
                </div>
                <div class="editor-label">
                    确认密码：
                </div>
                <div class="editor-field">
                    @Html.EditorFor(model => model.ConfirmPassword)
                    @Html.ValidationMessageFor(model => model.ConfirmPassword)
                </div>
            </div>
            <div class="field">
                <div class="editor-label">
                    @Html.LabelFor(model => model.UserType)
                </div>
                <div class="editor-field">
                    @Html.DropDownListFor(model => model.UserType, (SelectList)ViewBag.userTypeDropdownlist)
                </div>
                <div class="editor-label">
                    @Html.LabelFor(model => model.Email)
                </div>
                <div class="editor-field">
                    @Html.EditorFor(model => model.Email)
                    @Html.ValidationMessageFor(model => model.Email)
                </div>
            </div>
            <div class="field">
                <div class="editor-label">
                    @Html.LabelFor(model => model.Tel)
                </div>
                <div class="editor-field">
                    @Html.EditorFor(model => model.Tel)
                    @Html.ValidationMessageFor(model => model.Tel)
                </div>
                <div class="editor-label">
                    @Html.LabelFor(model => model.IM)
                </div>
                <div class="editor-field">
                    @Html.EditorFor(model => model.IM)
                    @Html.ValidationMessageFor(model => model.IM)
                </div>
            </div>
            <p>
                <input type="submit" value="创建用户" />
            </p>
        </fieldset>
    }
</div>
